Linux: Fix a bunch of clang errors from not handling return values.

Review URL: https://breakpad.appspot.com/421002

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@995 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
thestig@chromium.org 2012-07-24 00:15:53 +00:00
parent 63c7f7d7d7
commit 6b563c50dd
6 changed files with 61 additions and 13 deletions

View file

@ -35,6 +35,7 @@
#include "client/linux/crash_generation/crash_generation_client.h"
#include "common/linux/eintr_wrapper.h"
#include "common/linux/ignore_ret.h"
#include "common/linux/linux_libc_support.h"
#include "third_party/lss/linux_syscall_support.h"
@ -67,12 +68,14 @@ CrashGenerationClient::RequestDump(const void* blob, size_t blob_size)
int* p = reinterpret_cast<int*>(CMSG_DATA(hdr));
*p = fds[1];
HANDLE_EINTR(sys_sendmsg(server_fd_, &msg, 0));
ssize_t ret = HANDLE_EINTR(sys_sendmsg(server_fd_, &msg, 0));
sys_close(fds[1]);
if (ret <= 0)
return false;
// wait for an ACK from the server
char b;
HANDLE_EINTR(sys_read(fds[0], &b, 1));
IGNORE_RET(HANDLE_EINTR(sys_read(fds[0], &b, 1)));
return true;
}