aboutgitcodebugslistschat
path: root/tap.c
diff options
context:
space:
mode:
Diffstat (limited to 'tap.c')
-rw-r--r--tap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tap.c b/tap.c
index 11ac732..abeff25 100644
--- a/tap.c
+++ b/tap.c
@@ -757,7 +757,7 @@ redo:
rem = recv(c->fd_tap, p + n,
(ssize_t)sizeof(uint32_t) - n, 0);
if ((n += rem) != (ssize_t)sizeof(uint32_t))
- return 0;
+ return -EIO;
}
len = ntohl(*(uint32_t *)p);
@@ -771,7 +771,7 @@ redo:
if (len > n) {
rem = recv(c->fd_tap, p + n, len - n, 0);
if ((n += rem) != len)
- return 0;
+ return -EIO;
}
/* Complete the partial read above before discarding a malformed