Commit 7986cf28bc5050967a7056d6eadda7f16f84eaab
Committed by
James Morris
1 parent
da3f1c7b7d
Exists in
master
and in
4 other branches
TOMOYO: Fix build error with CONFIG_SECURITY_TOMOYO_OMIT_USERSPACE_LOADER=y .
I forgot to add #ifndef in commit 0e4ae0e0 "TOMOYO: Make several options configurable.", resulting security/built-in.o: In function `tomoyo_bprm_set_creds': tomoyo.c:(.text+0x4698e): undefined reference to `tomoyo_load_policy' error. Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Signed-off-by: James Morris <jmorris@namei.org>
Showing 1 changed file with 2 additions and 0 deletions Side-by-side Diff
security/tomoyo/tomoyo.c
... | ... | @@ -51,12 +51,14 @@ |
51 | 51 | */ |
52 | 52 | if (bprm->cred_prepared) |
53 | 53 | return 0; |
54 | +#ifndef CONFIG_SECURITY_TOMOYO_OMIT_USERSPACE_LOADER | |
54 | 55 | /* |
55 | 56 | * Load policy if /sbin/tomoyo-init exists and /sbin/init is requested |
56 | 57 | * for the first time. |
57 | 58 | */ |
58 | 59 | if (!tomoyo_policy_loaded) |
59 | 60 | tomoyo_load_policy(bprm->filename); |
61 | +#endif | |
60 | 62 | /* |
61 | 63 | * Release reference to "struct tomoyo_domain_info" stored inside |
62 | 64 | * "bprm->cred->security". New reference to "struct tomoyo_domain_info" |