From df7d32af22c3ab593727d521021096f677e767e2 Mon Sep 17 00:00:00 2001 From: Olaf Hering Date: Mon, 23 Aug 2004 21:41:13 -0700 Subject: [PATCH] [PATCH] compat_do_execve() fix For some reasons ls -l /proc/$$/exe doesnt work all time for me, with 2.6.8.1 on ppc64. Sometimes it does, sometimes not. No pattern. A few printks show that this check in proc_pid_readlink() triggers an -EACCES: current->fsuid != inode->i_uid proc_pid_readlink(755) error -13 ntptrace(11408) fsuid 100 i_uid 0 0 sys_readlink(281) ntptrace(11408) error -13 readlink Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- fs/compat.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/compat.c b/fs/compat.c index 3cddaab903548..7f471d7aa9c70 100644 --- a/fs/compat.c +++ b/fs/compat.c @@ -1392,6 +1392,8 @@ int compat_do_execve(char * filename, bprm.sh_bang = 0; bprm.loader = 0; bprm.exec = 0; + bprm.interp_flags = 0; + bprm.interp_data = 0; bprm.security = NULL; bprm.mm = mm_alloc(); retval = -ENOMEM; -- 2.53.0