1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-22 13:34:15 +03:00

lib/fuzzing:fuzz_sddl_access_check fix nul-term check

We were wanting to ensure the string contains a zero byte, but
instead were checking for a non-zero byte.

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
Douglas Bagnall 2023-08-05 14:18:46 +12:00 committed by Andrew Bartlett
parent 5c81f34935
commit c3ded9d934

View File

@ -103,7 +103,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *input, size_t len)
* all.
*/
for (i = len - 1; i >= 0; i--) {
if (input[i] != 0) {
if (input[i] == 0) {
break;
}
}