On Jan 27, 2014, at 3:28 AM, Jonathan Masters <[email protected]> wrote: > That's right, it's the reconnection which takes time, so I want to > reconnect and have the connection setup *before* the next time I need > to make a request. I don't want to only realise the connection is down > at the time the request comes in, which would mean I would have the > delay of connecting and the delay of the request.
Instead of poking in the cURL code, it would probably be easier if you made a NOOP request to your server to achieve the same thing? If there is no connection, curl will reconnect to do the noop. If there still is a connection, you just have a few bytes going back and forth (and you’d probably need that anyway to be 100% sure the connection is still alive). Regards, Fabian ------------------------------------------------------------------- List admin: http://cool.haxx.se/list/listinfo/curl-library Etiquette: http://curl.haxx.se/mail/etiquette.html
