mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-05 08:26:59 +00:00
Merge branch 'master' of git://git.infradead.org/users/pcmoore/selinux into next
This commit is contained in:
commit
923b49ff69
1 changed files with 13 additions and 1 deletions
|
@ -1995,7 +1995,19 @@ static int filename_trans_read(struct policydb *p, void *fp)
|
||||||
if (rc)
|
if (rc)
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
hashtab_insert(p->filename_trans, ft, otype);
|
rc = hashtab_insert(p->filename_trans, ft, otype);
|
||||||
|
if (rc) {
|
||||||
|
/*
|
||||||
|
* Do not return -EEXIST to the caller, or the system
|
||||||
|
* will not boot.
|
||||||
|
*/
|
||||||
|
if (rc != -EEXIST)
|
||||||
|
goto out;
|
||||||
|
/* But free memory to avoid memory leak. */
|
||||||
|
kfree(ft);
|
||||||
|
kfree(name);
|
||||||
|
kfree(otype);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
hash_eval(p->filename_trans, "filenametr");
|
hash_eval(p->filename_trans, "filenametr");
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Reference in a new issue