summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Morton <akpm@digeo.com>2003-05-12 09:09:56 -0700
committerLinus Torvalds <torvalds@home.transmeta.com>2003-05-12 09:09:56 -0700
commitf2248e8df63696954a4984fa5fa4d64a135f6de9 (patch)
treefaa0485df690185f515174f72bf50157dde85328
parenta7780700a81962993c7aefe71807b54a25be4a2b (diff)
[PATCH] hrtimers: fix timer_create(2) && SIGEV_NONE
From: george anzinger <george@mvista.com> - Fix the sig_notify filtering code for the timer_create system call to properly check for the signal number being small enought, but only if SIG_NONE is not specified. - Eliminate useless test of sig_notify.
-rw-r--r--kernel/posix-timers.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/kernel/posix-timers.c b/kernel/posix-timers.c
index bca12ba294e4..25757200b34d 100644
--- a/kernel/posix-timers.c
+++ b/kernel/posix-timers.c
@@ -357,13 +357,10 @@ static inline struct task_struct * good_sigevent(sigevent_t * event)
rtn->tgid != current->tgid))
return NULL;
- if ((event->sigev_notify & SIGEV_SIGNAL & MIPS_SIGEV) &&
+ if ((event->sigev_notify & ~SIGEV_NONE & MIPS_SIGEV) &&
((unsigned) (event->sigev_signo > SIGRTMAX)))
return NULL;
- if (event->sigev_notify & ~(SIGEV_SIGNAL | SIGEV_THREAD_ID))
- return NULL;
-
return rtn;
}