1
0
Fork 0

tools/testing/selftests: fix uninitialized variable

The err variable is intended to receive the timer_create() return before
checking it

Signed-off-by: Felipe Pena <felipensp@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
hifive-unleashed-5.1
Felipe Pena 2013-10-16 13:46:58 -07:00 committed by Linus Torvalds
parent 87fc0ad2ad
commit c88b05b2cd
1 changed files with 1 additions and 1 deletions

View File

@ -151,7 +151,7 @@ static int check_timer_create(int which)
fflush(stdout);
done = 0;
timer_create(which, NULL, &id);
err = timer_create(which, NULL, &id);
if (err < 0) {
perror("Can't create timer\n");
return -1;