summaryrefslogtreecommitdiff
path: root/dynstr.c
diff options
context:
space:
mode:
Diffstat (limited to 'dynstr.c')
-rw-r--r--dynstr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/dynstr.c b/dynstr.c
index 47cfad3..44c4b56 100644
--- a/dynstr.c
+++ b/dynstr.c
@@ -419,7 +419,7 @@ static size_t read_callback(FILE *f, int fd, unsigned char *buf, size_t size)
do {
n = read(fd, buf, size);
- } while (n == -1 && errno == EAGAIN);
+ } while (n == -1 && errno == EINTR);
if (n == -1)
return DYNSTR_ERROR;
return n;
@@ -530,7 +530,7 @@ static int readline_callback(FILE *f, int fd)
do {
n = read(fd, &c, 1);
- } while (n == -1 && errno == EAGAIN);
+ } while (n == -1 && errno == EINTR);
if (n == 0)
return -2;
else if (n == -1)