From: Daniel Stenberg Date: Thu, 1 Jul 2004 06:19:19 +0000 (+0000) Subject: don't close the trace stream until _after_ the easy handle has been cleaned X-Git-Tag: curl-7_12_1~166 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=087748c48eef2bf986660b628291dad857faca55;p=thirdparty%2Fcurl.git don't close the trace stream until _after_ the easy handle has been cleaned up, as that can send traces too --- diff --git a/src/main.c b/src/main.c index 126fa4af0a..6d8a21bf0e 100644 --- a/src/main.c +++ b/src/main.c @@ -3558,15 +3558,15 @@ operate(struct Configurable *config, int argc, char *argv[]) if(config->headerfile && !headerfilep && heads.stream) fclose(heads.stream); - if(config->trace_fopened && config->trace_stream) - fclose(config->trace_stream); - if(allocuseragent) free(config->useragent); /* cleanup the curl handle! */ curl_easy_cleanup(curl); + if(config->trace_fopened && config->trace_stream) + fclose(config->trace_stream); + if(config->errors_fopened) fclose(config->errors);