iliaa Wed Feb 25 19:02:29 2004 EDT
Modified files:
/php-src/ext/standard http_fopen_wrapper.c
Log:
Handle situation where feof() occurs before the HTTP header is retrieved.
http://cvs.php.net/diff.php/php-src/ext/standard/http_fopen_wrapper.c?r1=1.83&r2=1.84&ty=u
Index: php-src/ext/standard/http_fopen_wrapper.c
diff -u php-src/ext/standard/http_fopen_wrapper.c:1.83
php-src/ext/standard/http_fopen_wrapper.c:1.84
--- php-src/ext/standard/http_fopen_wrapper.c:1.83 Wed Feb 25 04:36:46 2004
+++ php-src/ext/standard/http_fopen_wrapper.c Wed Feb 25 19:02:27 2004
@@ -18,7 +18,7 @@
| Wez Furlong <[EMAIL PROTECTED]> |
+----------------------------------------------------------------------+
*/
-/* $Id: http_fopen_wrapper.c,v 1.83 2004/02/25 09:36:46 sebastian Exp $ */
+/* $Id: http_fopen_wrapper.c,v 1.84 2004/02/26 00:02:27 iliaa Exp $ */
#include "php.h"
#include "php_globals.h"
@@ -399,6 +399,9 @@
Z_TYPE_P(http_response) = IS_STRING;
zend_hash_next_index_insert(Z_ARRVAL_PP(response_header),
&http_response, sizeof(zval *), NULL);
}
+ } else {
+ php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "HTTP request
failed, unexpected end of socket.!");
+ goto out;
}
/* read past HTTP headers */
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php