Don't dereference null pointer should acl_alloc() be passed M_NOWAIT
and allocation failed. Nothing in the tree passed M_NOWAIT. Obtained from: mjg MFC after: 1 month
This commit is contained in:
parent
cc55ad3d72
commit
8ddc3590cc
@ -540,6 +540,9 @@ acl_alloc(int flags)
|
||||
struct acl *aclp;
|
||||
|
||||
aclp = malloc(sizeof(*aclp), M_ACL, flags);
|
||||
if (aclp == NULL)
|
||||
return (NULL);
|
||||
|
||||
aclp->acl_maxcnt = ACL_MAX_ENTRIES;
|
||||
|
||||
return (aclp);
|
||||
|
Loading…
Reference in New Issue
Block a user