summaryrefslogtreecommitdiffstats
path: root/src/buffio.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2004-01-08 21:21:42 +0000
committerLennart Poettering <lennart@poettering.net>2004-01-08 21:21:42 +0000
commit9f14b1b80e6b09e6b2dc067704fff2034dc0ad23 (patch)
treec54c5e55f901ef42849b4ce74e89a7207a70b6ce /src/buffio.c
parentaf93dd72c42bce9dc5528d7de9fd09ec285d8cb7 (diff)
Assorted work
git-svn-id: file:///home/lennart/svn/public/ivam2/trunk@18 dbf6933d-3bce-0310-9bcc-ed052ba35b35
Diffstat (limited to 'src/buffio.c')
-rw-r--r--src/buffio.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/buffio.c b/src/buffio.c
index 95db681..95e3dec 100644
--- a/src/buffio.c
+++ b/src/buffio.c
@@ -260,6 +260,10 @@ static void do_read(struct buffio *b) {
//daemon_log(LOG_INFO, "%p: Read %u (%u) bytes.", b, s, m);
if (s < 0) {
+
+ if (errno == EAGAIN)
+ return;
+
daemon_log(LOG_ERR, "Failed to read from file descriptor: %s", strerror(errno));
buffio_close_input_fd(b);
buffio_sched_cb(b, BUFFIO_SCHED_CB_ERROR);
@@ -309,6 +313,9 @@ static void do_write(struct buffio *b) {
//daemon_log(LOG_INFO, "%p: Wrote %u (%u) bytes.", b, s, m);
if (s < 0) {
+ if (errno == EAGAIN)
+ return;
+
buffio_close_output_fd(b);
if (errno == EPIPE) {