* [PATCH] Fix security.h compilation with !CONFIG_SECURITY
@ 2008-08-18 6:55 Andi Kleen
2008-08-18 18:58 ` Vegard Nossum
2008-08-18 19:22 ` David Howells
0 siblings, 2 replies; 3+ messages in thread
From: Andi Kleen @ 2008-08-18 6:55 UTC (permalink / raw)
To: torvalds; +Cc: linux-kernel, Andi Kleen, David Howells
From: Andi Kleen <ak@linux.intel.com>
This recent patch
commit 5cd9c58fbe9ec92b45b27e131719af4f2bd9eb40
Author: David Howells <dhowells@redhat.com>
Date: Thu Aug 14 11:37:28 2008 +0100
security: Fix setting of PF_SUPERPRIV by __capable()
broke compilation with !CONFIG_SECURITY:
linux/include/linux/security.h: In function 'security_ptrace_traceme':
linux/include/linux/security.h:1760: error: 'parent' undeclared (first use in this function)
Add the obvious fix.
Cc: David Howells <dhowells@redhat.com>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
---
include/linux/security.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/include/linux/security.h b/include/linux/security.h
index 2ee5ecf..0cc23a1 100644
--- a/include/linux/security.h
+++ b/include/linux/security.h
@@ -1757,7 +1757,7 @@ static inline int security_ptrace_may_access(struct task_struct *child,
static inline int security_ptrace_traceme(struct task_struct *child)
{
- return cap_ptrace_traceme(parent);
+ return cap_ptrace_traceme(child);
}
static inline int security_capget(struct task_struct *target,
--
1.5.6
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Fix security.h compilation with !CONFIG_SECURITY
2008-08-18 6:55 [PATCH] Fix security.h compilation with !CONFIG_SECURITY Andi Kleen
@ 2008-08-18 18:58 ` Vegard Nossum
2008-08-18 19:22 ` David Howells
1 sibling, 0 replies; 3+ messages in thread
From: Vegard Nossum @ 2008-08-18 18:58 UTC (permalink / raw)
To: Andi Kleen
Cc: torvalds, linux-kernel, Andi Kleen, David Howells, James Morris
On Mon, Aug 18, 2008 at 8:55 AM, Andi Kleen <andi@firstfloor.org> wrote:
> From: Andi Kleen <ak@linux.intel.com>
>
> This recent patch
>
> commit 5cd9c58fbe9ec92b45b27e131719af4f2bd9eb40
> Author: David Howells <dhowells@redhat.com>
> Date: Thu Aug 14 11:37:28 2008 +0100
>
> security: Fix setting of PF_SUPERPRIV by __capable()
>
> broke compilation with !CONFIG_SECURITY:
>
> linux/include/linux/security.h: In function 'security_ptrace_traceme':
> linux/include/linux/security.h:1760: error: 'parent' undeclared (first use in this function)
>
> Add the obvious fix.
>
> Cc: David Howells <dhowells@redhat.com>
> Signed-off-by: Andi Kleen <ak@linux.intel.com>
> ---
> include/linux/security.h | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/include/linux/security.h b/include/linux/security.h
> index 2ee5ecf..0cc23a1 100644
> --- a/include/linux/security.h
> +++ b/include/linux/security.h
> @@ -1757,7 +1757,7 @@ static inline int security_ptrace_may_access(struct task_struct *child,
>
> static inline int security_ptrace_traceme(struct task_struct *child)
> {
> - return cap_ptrace_traceme(parent);
> + return cap_ptrace_traceme(child);
> }
>
> static inline int security_capget(struct task_struct *target,
> --
Oops. I just submitted a similar patch. But I think yours is wrong.
The argument name should be "parent", as in the definition that is
provided when CONFIG_SECURITY=y.
int security_ptrace_traceme(struct task_struct *parent);
I'm sorry for the double submit.
Vegard
--
"The animistic metaphor of the bug that maliciously sneaked in while
the programmer was not looking is intellectually dishonest as it
disguises that the error is the programmer's own creation."
-- E. W. Dijkstra, EWD1036
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Fix security.h compilation with !CONFIG_SECURITY
2008-08-18 6:55 [PATCH] Fix security.h compilation with !CONFIG_SECURITY Andi Kleen
2008-08-18 18:58 ` Vegard Nossum
@ 2008-08-18 19:22 ` David Howells
1 sibling, 0 replies; 3+ messages in thread
From: David Howells @ 2008-08-18 19:22 UTC (permalink / raw)
To: Andi Kleen; +Cc: dhowells, torvalds, linux-kernel, Andi Kleen
Andi Kleen <andi@firstfloor.org> wrote:
> static inline int security_ptrace_traceme(struct task_struct *child)
This should be parent, not child.
David
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2008-08-18 19:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-08-18 6:55 [PATCH] Fix security.h compilation with !CONFIG_SECURITY Andi Kleen
2008-08-18 18:58 ` Vegard Nossum
2008-08-18 19:22 ` David Howells
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).