requiring 'name != NULL' in find_cipher_any() doesn't make sense

This commit is contained in:
Steffen Jaeckel 2017-06-07 23:42:33 +02:00
parent 7aaa423004
commit 7f91e5ae65

View File

@ -26,10 +26,10 @@ int find_cipher_any(const char *name, int blocklen, int keylen)
{
int x;
LTC_ARGCHK(name != NULL);
x = find_cipher(name);
if (x != -1) return x;
if(name != NULL) {
x = find_cipher(name);
if (x != -1) return x;
}
LTC_MUTEX_LOCK(&ltc_cipher_mutex);
for (x = 0; x < TAB_SIZE; x++) {