Commit Diff
- Commit:
d95d69074c849c2f95e9f12f2cd4403a60ba30fe
- From:
- Stefan Sperling <stsp@stsp.name>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
- Message:
- gotsh: do not set POLLOUT flag when there is no data to send Prevent an endless polling loop on Linux where POLLOUT and POLLHUP can both be reported via pollfd revents.
- Actions:
- Patch | Tree
--- lib/serve.c +++ lib/serve.c @@ -1101,7 +1101,7 @@ recv_packfile(struct imsg *imsg, int infd) if (r == 0) { /* Detect gotd(8) closing the pack pipe when done. */ - err = got_poll_fd(packfd, POLLOUT, 1); + err = got_poll_fd(packfd, 0, 1); if (err) { if (err->code != GOT_ERR_EOF) break;