Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(783)

Unified Diff: ipc/file_descriptor_set_posix.cc

Issue 2805026: Clang: Do not ignore result of HANDLE_EINTR. (Closed)
Patch Set: '' Created 10 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ipc/file_descriptor_set_posix.cc
diff --git a/ipc/file_descriptor_set_posix.cc b/ipc/file_descriptor_set_posix.cc
index 3796fae6a04e757b16605ab8da83962389ba4053..7f17322de47b2f46095604b3be6763db0d71ee96 100644
--- a/ipc/file_descriptor_set_posix.cc
+++ b/ipc/file_descriptor_set_posix.cc
@@ -30,7 +30,8 @@ FileDescriptorSet::~FileDescriptorSet() {
for (unsigned i = consumed_descriptor_highwater_;
i < descriptors_.size(); ++i) {
if (descriptors_[i].auto_close)
- HANDLE_EINTR(close(descriptors_[i].fd));
+ if (HANDLE_EINTR(close(descriptors_[i].fd)) < 0)
+ PLOG(ERROR) << "close";
}
}
@@ -113,7 +114,8 @@ void FileDescriptorSet::CommitAll() {
for (std::vector<base::FileDescriptor>::iterator
i = descriptors_.begin(); i != descriptors_.end(); ++i) {
if (i->auto_close)
- HANDLE_EINTR(close(i->fd));
+ if (HANDLE_EINTR(close(i->fd)) < 0)
+ PLOG(ERROR) << "close";
}
descriptors_.clear();
consumed_descriptor_highwater_ = 0;

Powered by Google App Engine
This is Rietveld 408576698