projects
/
platform
/
upstream
/
nodejs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
88b9359
)
Ignore EAGAIN in stderr dumps.
author
Ryan Dahl
<ry@tinyclouds.org>
Tue, 9 Feb 2010 22:42:56 +0000
(14:42 -0800)
committer
Ryan Dahl
<ry@tinyclouds.org>
Tue, 9 Feb 2010 22:45:14 +0000
(14:45 -0800)
(Going out of the way to be sync)
src/node_stdio.cc
patch
|
blob
|
history
diff --git
a/src/node_stdio.cc
b/src/node_stdio.cc
index
cda79e3
..
2b5b306
100644
(file)
--- a/
src/node_stdio.cc
+++ b/
src/node_stdio.cc
@@
-68,7
+68,13
@@
WriteError (const Arguments& args)
size_t written = 0;
while (written < msg.length()) {
r = write(STDERR_FILENO, (*msg) + written, msg.length() - written);
- if (r < 0) return ThrowException(errno_exception(errno));
+ if (r < 0) {
+ if (errno == EAGAIN || errno == EIO) {
+ usleep(100);
+ continue;
+ }
+ return ThrowException(errno_exception(errno));
+ }
written += (size_t)r;
}