diff options
author | Přemysl Janouch <p@janouch.name> | 2019-02-24 01:41:15 +0100 |
---|---|---|
committer | Přemysl Janouch <p@janouch.name> | 2019-02-24 01:41:15 +0100 |
commit | 6c1546e9190970aff32401277a8c5609bfa67f1c (patch) | |
tree | ad070fca397150b4aaa5a7cd8a0a90a70c21c139 /nncmpp.c | |
parent | 15e583beb298399cc4deff1aad31e4ec5deda4bc (diff) | |
download | nncmpp-6c1546e9190970aff32401277a8c5609bfa67f1c.tar.gz nncmpp-6c1546e9190970aff32401277a8c5609bfa67f1c.tar.xz nncmpp-6c1546e9190970aff32401277a8c5609bfa67f1c.zip |
Workaround cURL bug
Diffstat (limited to 'nncmpp.c')
-rw-r--r-- | nncmpp.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -286,6 +286,9 @@ poller_curl_on_socket_action (CURL *easy, curl_socket_t s, int what, } if (what == CURL_POLL_REMOVE) { + // Some annoying cURL bug. Never trust libraries. + fd->fd.closed = fcntl(fd->fd.fd, F_GETFL) < 0 && errno == EBADF; + poller_fd_reset (&fd->fd); LIST_UNLINK (self->fds, fd); free (fd); |