From 432918433d1b04e94864c09949dda59bc1454271 Mon Sep 17 00:00:00 2001 From: Ted Ross Date: Wed, 14 Sep 2011 21:41:11 +0000 Subject: QPID-3484 - Fixed handling of unused return values to prevent compiler warnings. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1170860 13f79535-47bb-0310-9956-ffa450edef68 --- qpid/cpp/src/qmf/PosixEventNotifierImpl.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'qpid/cpp/src/qmf/PosixEventNotifierImpl.cpp') diff --git a/qpid/cpp/src/qmf/PosixEventNotifierImpl.cpp b/qpid/cpp/src/qmf/PosixEventNotifierImpl.cpp index abc9cadcfa..011dbcc214 100644 --- a/qpid/cpp/src/qmf/PosixEventNotifierImpl.cpp +++ b/qpid/cpp/src/qmf/PosixEventNotifierImpl.cpp @@ -18,9 +18,11 @@ */ #include "PosixEventNotifierImpl.h" +#include "qpid/log/Statement.h" #include #include +#include #define BUFFER_SIZE 10 @@ -51,10 +53,12 @@ void PosixEventNotifierImpl::update(bool readable) char buffer[BUFFER_SIZE]; if(readable && !this->isReadable()) { - (void) ::write(myHandle, "1", 1); + if (::write(myHandle, "1", 1) == -1) + QPID_LOG(error, "PosixEventNotifierImpl::update write failed: " << errno); } else if(!readable && this->isReadable()) { - (void) ::read(yourHandle, buffer, BUFFER_SIZE); + if (::read(yourHandle, buffer, BUFFER_SIZE) == -1) + QPID_LOG(error, "PosixEventNotifierImpl::update read failed: " << errno); } } -- cgit v1.2.1