ITS#7851 contrib pw-sha2 fix int/size_t comparison

This commit is contained in:
ryan@nardis.ca 2014-06-27 02:18:13 +00:00 committed by Howard Chu
parent 9b36358270
commit b54ae0e2bd

View file

@ -244,7 +244,7 @@ static int chk_ssha256(
rc = lutil_b64_pton(passwd->bv_val, orig_pass, decode_len);
if( rc <= sizeof(SHAdigest) ) {
if( rc <= (int)(sizeof(SHAdigest)) ) {
ber_memfree(orig_pass);
return LUTIL_PASSWD_ERR;
}
@ -332,7 +332,7 @@ static int chk_ssha384(
rc = lutil_b64_pton(passwd->bv_val, orig_pass, decode_len);
if( rc <= sizeof(SHAdigest) ) {
if( rc <= (int)(sizeof(SHAdigest)) ) {
ber_memfree(orig_pass);
return LUTIL_PASSWD_ERR;
}
@ -420,7 +420,7 @@ static int chk_ssha512(
rc = lutil_b64_pton(passwd->bv_val, orig_pass, decode_len);
if( rc <= sizeof(SHAdigest) ) {
if( rc <= (int)(sizeof(SHAdigest)) ) {
ber_memfree(orig_pass);
return LUTIL_PASSWD_ERR;
}