cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: not receiving CURLMSG_DONE or other end-of-transfer signals

From: Anthony Avina <aavina2_at_gmail.com>
Date: Thu, 23 Apr 2015 01:32:08 -0500

> >>>An instant later, more data arrives. How does libcurl find out? .. if the application is using edge-triggered notifications (e.g., epoll() with EPOLLET, or recent asio), the OS doesn't tell it that new data has arrived
>
> This is wrong. I misread epoll's documentation. As long as we loop until we receive EAGAIN, a subsequent call to epoll will again notify on the socket.
>
> Yet the behavior I am seeing is a lack of notifications from epoll, causing libcurl to wait forever to read more data on the socket.
>
> Back to head-scratching...
>
> --Daniel
It wouldn't hurt to disable edge-triggering if you still wanted to
give that a shot. I've no idea where epoll is initialized in the code.
I've ctrl-f'ed and couldn't find it but the modification should be as
simple as this:

ev.events = EPOLLIN | EPOLLET; /* Old line */
ev.events = EPOLLIN; /* Modified line */

--Anthony
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2015-04-23