From: Nick Mathewson Date: Fri, 17 Feb 2012 15:42:56 +0000 (-0500) Subject: Fix an "unused return value" warning on write() in signal handler X-Git-Tag: release-2.1.1-alpha~87 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=65bc91c210b75ae924111919eee56ec54ecd27ee;p=libevent Fix an "unused return value" warning on write() in signal handler --- diff --git a/signal.c b/signal.c index 5d73ea80..e279f5e8 100644 --- a/signal.c +++ b/signal.c @@ -397,7 +397,10 @@ evsig_handler(int sig) #ifdef _WIN32 send(evsig_base_fd, (char*)&msg, 1, 0); #else - write(evsig_base_fd, (char*)&msg, 1); + { + int r = write(evsig_base_fd, (char*)&msg, 1); + (void)r; /* Suppress 'unused return value' and 'unused var' */ + } #endif errno = save_errno; #ifdef _WIN32