compare against MAX_UNICODE_SZ, readability change

This commit is contained in:
Ruby Martin
2026-05-06 09:28:43 -06:00
parent dbdd066737
commit d960d02c80
+2 -2
View File
@@ -468,8 +468,8 @@ int wc_CryptKey(const char* password, int passwordSz, const byte* salt,
byte unicodePasswd[MAX_UNICODE_SZ];
if (passwordSz < 0 ||
passwordSz >= (int)sizeof(unicodePasswd) ||
(passwordSz * 2 + 2) > (int)sizeof(unicodePasswd)) {
passwordSz >= MAX_UNICODE_SZ ||
(passwordSz * 2 + 2) > MAX_UNICODE_SZ) {
ret = UNICODE_SIZE_E;
break;
}