Commit 8132b65b authored by Stanislav Fomichev's avatar Stanislav Fomichev Committed by Steve French
Browse files

cifs: add check for kmalloc in parse_dacl

Exit from parse_dacl if no memory returned from the call to kmalloc.

Signed-off-by: default avatarStanislav Fomichev <>
Signed-off-by: default avatarSteve French <>
parent 247ec9b4
......@@ -372,6 +372,10 @@ static void parse_dacl(struct cifs_acl *pdacl, char *end_of_acl,
ppace = kmalloc(num_aces * sizeof(struct cifs_ace *),
if (!ppace) {
cERROR(1, "DACL memory allocation error");
for (i = 0; i < num_aces; ++i) {
ppace[i] = (struct cifs_ace *) (acl_base + acl_size);
Supports Markdown
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