From e541da93fee32afb38b6ac86cefc62155130861a Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Thu, 23 Mar 2000 10:41:16 +0000 Subject: [PATCH] in case the select() returns -1 and errno is EINTR, it should not abort the download (MT-adjustment) --- lib/download.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lib/download.c b/lib/download.c index 055217c01..380330b1b 100644 --- a/lib/download.c +++ b/lib/download.c @@ -194,7 +194,14 @@ Transfer (struct UrlData *data, switch (select (maxfd, &readfd, &writefd, NULL, &interval)) { case -1: /* select() error, stop reading */ - keepon = 0; /* no more read or write */ +#ifdef EINTR + /* The EINTR is not serious, and it seems you might get this more + ofen when using the lib in a multi-threaded environment! */ + if(errno == EINTR) + ; + else +#endif + keepon = 0; /* no more read or write */ continue; case 0: /* timeout */ break;