Fix signed/unsigned comparison warning.

This commit is contained in:
Milan Broz
2018-11-25 15:11:44 +01:00
parent 3d2fd06035
commit 9a2dbb26a5

View File

@@ -238,7 +238,7 @@ int crypt_cipher_check(const char *name, const char *mode,
else
r = snprintf(tmp_salg_name, sizeof(tmp_salg_name), "%s(%s)", real_mode, name);
if (r <= 0 || r > (sizeof(sa.salg_name) - 1))
if (r <= 0 || r > (int)(sizeof(sa.salg_name) - 1))
return -EINVAL;
memcpy(sa.salg_name, tmp_salg_name, sizeof(sa.salg_name));