diff options
Diffstat (limited to 'lib/conncache.c')
-rw-r--r-- | lib/conncache.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/conncache.c b/lib/conncache.c index 95fcea6f3..4474c28b4 100644 --- a/lib/conncache.c +++ b/lib/conncache.c @@ -531,6 +531,11 @@ Curl_conncache_extract_oldest(struct Curl_easy *data) void Curl_conncache_close_all_connections(struct conncache *connc) { struct connectdata *conn; + char buffer[READBUFFER_MIN]; + if(!connc->closure_handle) + return; + connc->closure_handle->state.buffer = buffer; + connc->closure_handle->set.buffer_size = READBUFFER_MIN; conn = conncache_find_first_connection(connc); while(conn) { @@ -547,6 +552,7 @@ void Curl_conncache_close_all_connections(struct conncache *connc) conn = conncache_find_first_connection(connc); } + connc->closure_handle->state.buffer = NULL; if(connc->closure_handle) { SIGPIPE_VARIABLE(pipe_st); sigpipe_ignore(connc->closure_handle, &pipe_st); |