cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: curl_easy_perform crash in Curl_do after Curl_reconnect_request has been called

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 17 Dec 2010 23:42:23 +0100 (CET)

On Thu, 16 Dec 2010, Pasha Kuznetsov wrote:

> result = Curl_reconnect_request(connp);
>
> if(result == CURLE_OK) {
> /* ... finally back to actually retry the DO phase */
> result = conn->handler->do_it(conn, done);
>
> Please note that the original `conn' pointer is used after the `connectdata'
> it points to has been closed/cleaned up by Curl_reconnect_request.

Quite clearly, yes indeed.

> I believe the code above should be modified along the following lines:
> ...
> result = Curl_reconnect_request(connp);
> conn = *connp;

So could you repeat this problem so that you could verify that this actually
also solved your problem?

Thanks a lot for your report and research on this!

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2010-12-17