cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Closing an open connection with curl easy handle

From: Thibaut Le Guilly <leguilly.thibaut_at_gmail.com>
Date: Fri, 30 Sep 2011 09:17:09 +0200

Hi,

Thank you very much for the information, I went through all the
documentation without thinking about reading the FAQ, sorry for that!

I succeeded to stop the transfer by returning an appropriate value from the
write callback when I need to. But I don't really like this solution because
it will have to wait for the server to send a notification in order for the
write callback to be called, which may take some time.

I also tried with the multi interface, and also succeeded to properly close
the connection by removing the easy handle from the multi stack, but then
the problem is that I have to call the curl_multi_perform() function each
time I want to check if the server sent notifications. Looking at the multi
interface I saw the curl_multi_socket_action, but I'm not sure I totatlly
understood this functionality. Can I use that to detect when the server push
information to the client?

Thanks a lot for your help,

Best regards,

-- 
Thibaut

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-09-30