aboutsummaryrefslogtreecommitdiff
path: root/lib/http.c
diff options
context:
space:
mode:
authorDan Fandrich <dan@coneharvesters.com>2007-04-10 00:38:41 +0000
committerDan Fandrich <dan@coneharvesters.com>2007-04-10 00:38:41 +0000
commit910ee13b20b622b9aa0c53025d86b19e9dcdf586 (patch)
treef970a3c40a00fd2d35d21e71f1ad58a42020f22d /lib/http.c
parent35935d71d2c0d4448ca123f8a9e888361c1f9102 (diff)
Fixed an out of memory handling issue.
Diffstat (limited to 'lib/http.c')
-rw-r--r--lib/http.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/http.c b/lib/http.c
index 011f1141e..8e4d322af 100644
--- a/lib/http.c
+++ b/lib/http.c
@@ -1206,15 +1206,18 @@ CURLcode Curl_proxyCONNECT(struct connectdata *conn,
/* CRLF terminate the request */
result = add_bufferf(req_buffer, "\r\n");
- if(CURLE_OK == result)
+ if(CURLE_OK == result) {
/* Now send off the request */
result = add_buffer_send(req_buffer, conn,
&data->info.request_size, 0, sockindex);
+ req_buffer = NULL;
+ }
}
if(result)
failf(data, "Failed sending CONNECT to proxy");
}
free(host_port);
+ Curl_safefree(req_buffer);
if(result)
return result;