diff options
-rw-r--r-- | file_descriptor.cc | 2 | ||||
-rw-r--r-- | omaha_hash_calculator.cc | 2 | ||||
-rw-r--r-- | utils.h | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/file_descriptor.cc b/file_descriptor.cc index 255307d3..f6b55bb7 100644 --- a/file_descriptor.cc +++ b/file_descriptor.cc @@ -48,7 +48,7 @@ ssize_t EintrSafeFileDescriptor::Write(const void* buf, size_t count) { bool EintrSafeFileDescriptor::Close() { CHECK_GE(fd_, 0); - if (HANDLE_EINTR(close(fd_))) + if (IGNORE_EINTR(close(fd_))) return false; Reset(); return true; diff --git a/omaha_hash_calculator.cc b/omaha_hash_calculator.cc index 2159d281..f5237a21 100644 --- a/omaha_hash_calculator.cc +++ b/omaha_hash_calculator.cc @@ -91,7 +91,7 @@ off_t OmahaHashCalculator::UpdateFile(const string& name, off_t length) { } bytes_processed += rc; } - HANDLE_EINTR(close(fd)); + IGNORE_EINTR(close(fd)); return bytes_processed; } @@ -480,7 +480,7 @@ class ScopedEintrSafeFdCloser { explicit ScopedEintrSafeFdCloser(int* fd) : fd_(fd), should_close_(true) {} ~ScopedEintrSafeFdCloser() { if (should_close_ && fd_ && (*fd_ >= 0)) { - if (!HANDLE_EINTR(close(*fd_))) + if (!IGNORE_EINTR(close(*fd_))) *fd_ = -1; } } |