From d1602669bcbc2eb96851429ac3008ea6b3b0163b Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 6 Jun 2005 12:42:51 +0000 Subject: [PATCH] - MFH: Fixed bug #33242 (Mangled error message when stream fails). --- NEWS | 1 + ext/standard/http_fopen_wrapper.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/NEWS b/NEWS index cdd463ec88..4abc2533f5 100644 --- a/NEWS +++ b/NEWS @@ -10,6 +10,7 @@ PHP 4 NEWS - Fixed memory corruptions when using references in a wrong way. (Marcus, Dmitry, Derick) - Fixed memory corruption in stristr(). (Derick) +- Fixed bug #33242 (Mangled error message when stream fails). (Derick) - Fixed bug #33222 (segfault when CURL handle is closed in a callback). (Tony) - Fixed bug #33214 (odbc_next_result does not signal SQL errors with 2-statement SQL batches). (rich at kastle dot com, Tony) diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c index 0e2bc274ab..c67688d300 100644 --- a/ext/standard/http_fopen_wrapper.c +++ b/ext/standard/http_fopen_wrapper.c @@ -107,6 +107,8 @@ php_stream *php_stream_url_wrap_http_ex(php_stream_wrapper *wrapper, char *path, size_t chunk_size = 0, file_size = 0; int eol_detect, have_header = 0; + tmp_line[0] = '\0'; + if (redirect_max < 1) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Circular redirect, aborting."); return NULL; -- 2.40.0