projects
/
oweals
/
gnunet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
61a374c
)
LRN: Fix select() on pipes to trigger read callback on EPIPE
author
Christian Grothoff
<christian@grothoff.org>
Thu, 6 Oct 2011 08:47:42 +0000
(08:47 +0000)
committer
Christian Grothoff
<christian@grothoff.org>
Thu, 6 Oct 2011 08:47:42 +0000
(08:47 +0000)
src/util/network.c
patch
|
blob
|
history
diff --git
a/src/util/network.c
b/src/util/network.c
index 320304fe2de19a7976ee9696ee403f7f4f83ec4e..3be21599eef8302db8c8599e5d66787a50224153 100644
(file)
--- a/
src/util/network.c
+++ b/
src/util/network.c
@@
-1531,7
+1531,12
@@
GNUNET_NETWORK_socket_select (struct GNUNET_NETWORK_FDSet *rfds,
"Peek at read pipe %d (0x%x) returned %d (%d bytes available) GLE %u\n",
i, readArray[i]->h, bret, waitstatus, error);
#endif
- if (bret == 0 || waitstatus <= 0)
+ if (bret == 0)
+ {
+ if (error != ERROR_BROKEN_PIPE)
+ continue;
+ }
+ else if (waitstatus <= 0)
continue;
GNUNET_CONTAINER_slist_add (handles_read,
GNUNET_CONTAINER_SLIST_DISPOSITION_TRANSIENT,