Skip to content

Commit

Permalink
fix error-path NULL deref in alloc_posix_timer()
Browse files Browse the repository at this point in the history
Found by static checker (http://repo.or.cz/w/smatch.git).

Signed-off-by: Dan Carpenter <[email protected]>
Acked-by: Thomas Gleixner <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
error27 authored and torvalds committed Oct 2, 2008
1 parent c0c9209 commit aa94fbd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kernel/posix-timers.c
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ static struct k_itimer * alloc_posix_timer(void)
return tmr;
if (unlikely(!(tmr->sigq = sigqueue_alloc()))) {
kmem_cache_free(posix_timers_cache, tmr);
tmr = NULL;
return NULL;
}
memset(&tmr->sigq->info, 0, sizeof(siginfo_t));
return tmr;
Expand Down

0 comments on commit aa94fbd

Please sign in to comment.