From a05acc1abbde8f9c86ea5c03d9e60d8efe5f6920 Mon Sep 17 00:00:00 2001 From: Masayuki Ishikawa Date: Thu, 2 Mar 2017 13:40:43 +0900 Subject: [PATCH 1/2] Remove an unused variable when calling sigtimedwait() --- examples/gpio/gpio_main.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/examples/gpio/gpio_main.c b/examples/gpio/gpio_main.c index ba3ac515f..9332af985 100644 --- a/examples/gpio/gpio_main.c +++ b/examples/gpio/gpio_main.c @@ -250,7 +250,6 @@ int gpio_main(int argc, char *argv[]) if (havesigno) { struct timespec ts; - struct siginfo info; sigset_t set; /* Set up to receive signal */ @@ -273,7 +272,7 @@ int gpio_main(int argc, char *argv[]) ts.tv_sec = 5; ts.tv_nsec = 0; - ret = sigtimedwait(&set, &info, &ts); + ret = sigtimedwait(&set, NULL, &ts); (void)ioctl(fd, GPIOC_UNREGISTER, 0); if (ret < 0) From 5382806c5a4612061b7724a8b6dee8262f39ebdf Mon Sep 17 00:00:00 2001 From: Masayuki Ishikawa Date: Thu, 2 Mar 2017 13:41:08 +0900 Subject: [PATCH 2/2] Remove an unused variable when calling sigwaitinfo() --- examples/oneshot/oneshot_main.c | 3 +-- graphics/traveler/src/trv_input.c | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/examples/oneshot/oneshot_main.c b/examples/oneshot/oneshot_main.c index 769f1a7fd..8747f79c9 100644 --- a/examples/oneshot/oneshot_main.c +++ b/examples/oneshot/oneshot_main.c @@ -116,7 +116,6 @@ int oneshot_main(int argc, char *argv[]) unsigned long usecs = CONFIG_EXAMPLE_ONESHOT_DELAY; unsigned long secs; struct oneshot_start_s start; - struct siginfo info; struct timespec ts; uint64_t maxus; sigset_t set; @@ -252,7 +251,7 @@ int oneshot_main(int argc, char *argv[]) /* Wait for the oneshot to fire */ printf("Waiting...\n"); - ret = sigwaitinfo(&set, &info); + ret = sigwaitinfo(&set, NULL); if (ret < 0) { fprintf(stderr, "ERROR: sigwaitinfo failed: %d\n", diff --git a/graphics/traveler/src/trv_input.c b/graphics/traveler/src/trv_input.c index c14dc42af..becf873c3 100644 --- a/graphics/traveler/src/trv_input.c +++ b/graphics/traveler/src/trv_input.c @@ -146,14 +146,13 @@ static struct trv_joystick_s g_trv_joystick; static int trv_joystick_wait(void) { sigset_t set; - struct siginfo value; int ret; /* Wait for a signal */ (void)sigemptyset(&set); (void)sigaddset(&set, CONFIG_GRAPHICS_TRAVELER_JOYSTICK_SIGNO); - ret = sigwaitinfo(&set, &value); + ret = sigwaitinfo(&set, NULL); if (ret < 0) { int errcode = errno;