Merge branch 'jk/maint-gc-auto-after-fetch' into jk/gc-auto-after-fetch
[gitweb.git] / compat / poll / poll.c
index e4b8319fb7335bfc31eb3e1e96605f077e2b568d..7d226ecb293ee3c5f9b17aa3e5e36b7c8701dbae 100644 (file)
@@ -306,6 +306,10 @@ compute_revents (int fd, int sought, fd_set *rfds, fd_set *wfds, fd_set *efds)
               || socket_errno == ECONNABORTED || socket_errno == ENETRESET)
        happened |= POLLHUP;
 
+      /* some systems can't use recv() on non-socket, including HP NonStop */
+      else if (/* (r == -1) && */ socket_errno == ENOTSOCK)
+       happened |= (POLLIN | POLLRDNORM) & sought;
+
       else
        happened |= POLLERR;
     }