diff options
-rw-r--r-- | ext/standard/http_fopen_wrapper.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c index 2074bf28ec..948d736b48 100644 --- a/ext/standard/http_fopen_wrapper.c +++ b/ext/standard/http_fopen_wrapper.c @@ -407,7 +407,9 @@ php_stream *php_stream_url_wrap_http_ex(php_stream_wrapper *wrapper, char *path, have_header |= HTTP_HEADER_TYPE; } } - efree(tmp); + if (tmp) { + efree(tmp); + } } /* auth header if it was specified */ |