diff options
author | Fernando Carrijo <fcarrijo@yahoo.com.br> | 2010-08-03 11:50:52 +0200 |
---|---|---|
committer | Tiago Vignatti <tiago.vignatti@nokia.com> | 2010-08-03 18:29:48 +0300 |
commit | e37240e3b01f1167964d2eb5c1748c356df7b2f5 (patch) | |
tree | 6d3a63b769106f453fd481688c100d0604e4daaa | |
parent | 5e75206b4dc02d0a070725b805fb3eb633341986 (diff) |
os: inputthread: don't get a return value on WaitForInput
Since WaitForInput exists for the sole purpose of being used as a thread
routine, we can afford to declare its return type as void*, which is the
most natural choice considering pthreads usage.
Signed-off-by: Fernando Carrijo <fcarrijo@yahoo.com.br>
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
-rw-r--r-- | os/inputthread.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/os/inputthread.c b/os/inputthread.c index 02edda4b3..676c7cc2f 100644 --- a/os/inputthread.c +++ b/os/inputthread.c @@ -81,7 +81,7 @@ AddEnabledDeviceThreaded(int fd, void (*f)(void *), void *closure) * process exits only when the main thread (parent) send a signal or a * fatal error occurs. */ -static int +static void* WaitForInput(void* argument) { int i; @@ -149,7 +149,7 @@ CreateInputThread (void) if (pthread_attr_setstacksize(&attr, PTHREAD_STACK_MIN) != 0) perror("error setting input thread stack size"); - pthread_create(&input_thread, &attr, (void *)&WaitForInput, NULL); + pthread_create(&input_thread, &attr, &WaitForInput, NULL); pthread_attr_destroy (&attr); } |