Commit 1214e334 authored by Andreas Schneider's avatar Andreas Schneider Committed by Jeremy Allison

s3-libsmb: Fix scanf format in parse_ace().

Signed-off-by: Andreas Schneider's avatarAndreas Schneider <[email protected]>
Reviewed-by: Jeremy Allison's avatarJeremy Allison <[email protected]>
parent 278899f5
......@@ -303,7 +303,7 @@ parse_ace(struct cli_state *ipc_cli,
p++;
/* Try to parse numeric form */
if (sscanf(p, "%i/%i/%i", &atype, &aflags, &amask) == 3 &&
if (sscanf(p, "%u/%u/%u", &atype, &aflags, &amask) == 3 &&
convert_string_to_sid(ipc_cli, pol, numeric, &sid, str)) {
goto done;
}
......@@ -333,7 +333,7 @@ parse_ace(struct cli_state *ipc_cli,
/* Only numeric form accepted for flags at present */
if (!(next_token_talloc(frame, &cp, &tok, "/") &&
sscanf(tok, "%i", &aflags))) {
sscanf(tok, "%u", &aflags))) {
TALLOC_FREE(frame);
return false;
}
......@@ -344,7 +344,7 @@ parse_ace(struct cli_state *ipc_cli,
}
if (strncmp(tok, "0x", 2) == 0) {
if (sscanf(tok, "%i", &amask) != 1) {
if (sscanf(tok, "%u", &amask) != 1) {
TALLOC_FREE(frame);
return false;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment