From 247452456c81629ccd726469459875185fb78c82 Mon Sep 17 00:00:00 2001 From: Roland Dreier Date: Mon, 28 Mar 2011 14:13:35 -0700 Subject: [PATCH] --- yaml --- r: 243201 b: refs/heads/master c: 243b422af9ea9af4ead07a8ad54c90d4f9b6081a h: refs/heads/master i: 243199: c9c8f67b8e1dce082cbcaa32b97f8bbaca99ec65 v: v3 --- [refs] | 2 +- trunk/kernel/signal.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index a3bd636e7a63..ee29c4be7ede 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 5847098cd896c92819800e17e983bf6530035209 +refs/heads/master: 243b422af9ea9af4ead07a8ad54c90d4f9b6081a diff --git a/trunk/kernel/signal.c b/trunk/kernel/signal.c index 324eff5468ad..1186cf7fac77 100644 --- a/trunk/kernel/signal.c +++ b/trunk/kernel/signal.c @@ -2437,7 +2437,7 @@ SYSCALL_DEFINE3(rt_sigqueueinfo, pid_t, pid, int, sig, /* Not even root can pretend to send signals from the kernel. * Nor can they impersonate a kill()/tgkill(), which adds source info. */ - if (info.si_code != SI_QUEUE) { + if (info.si_code >= 0 || info.si_code == SI_TKILL) { /* We used to allow any < 0 si_code */ WARN_ON_ONCE(info.si_code < 0); return -EPERM; @@ -2457,7 +2457,7 @@ long do_rt_tgsigqueueinfo(pid_t tgid, pid_t pid, int sig, siginfo_t *info) /* Not even root can pretend to send signals from the kernel. * Nor can they impersonate a kill()/tgkill(), which adds source info. */ - if (info->si_code != SI_QUEUE) { + if (info->si_code >= 0 || info->si_code == SI_TKILL) { /* We used to allow any < 0 si_code */ WARN_ON_ONCE(info->si_code < 0); return -EPERM;