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

Unified Diff: src/eventloop-integration.cpp

Issue 1648006: Apply patch from ebuild file to fix toString (Closed)
Patch Set: Created 10 years, 8 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
« no previous file with comments | « src/error.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/eventloop-integration.cpp
diff --git a/src/eventloop-integration.cpp b/src/eventloop-integration.cpp
index d8015749784f8b85392a3a099a52390ad1f47a92..0d5d2728b02c04e844d829ba176445d3629f13f5 100644
--- a/src/eventloop-integration.cpp
+++ b/src/eventloop-integration.cpp
@@ -90,8 +90,12 @@ void BusDispatcher::leave()
_running = false;
int ret = write(_fdunlock[1],"exit",strlen("exit"));
- if (ret == -1) throw Error("WriteError:errno", toString(errno).c_str());
-
+ if (ret == -1) {
+ char buffer[128]; // buffer copied in Error constructor
+ throw Error("PipeError:errno", strerror_r(errno,
+ buffer,
+ sizeof(buffer)));
+ }
close(_fdunlock[1]);
close(_fdunlock[0]);
}
@@ -172,4 +176,3 @@ void BusDispatcher::watch_ready(DefaultWatch &ew)
watch->handle(flags);
}
-
« no previous file with comments | « src/error.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698