cvs: pecl /http http_send_api.c

From: Date: Tue, 17 Oct 2006 19:13:16 +0000
Subject: cvs: pecl /http http_send_api.c
Groups: php.pecl.cvs 
Request: Send a blank email to pecl-cvs+get-6498@lists.php.net to get a copy of this message
mike Tue Oct 17 19:13:16 2006 UTC Modified files: /pecl/http http_send_api.c Log: - fix crash if *val == NULL http://cvs.php.net/viewvc.cgi/pecl/http/http_send_api.c?r1=1.64&r2=1.65&diff_format=u Index: pecl/http/http_send_api.c diff -u pecl/http/http_send_api.c:1.64 pecl/http/http_send_api.c:1.65 --- pecl/http/http_send_api.c:1.64 Tue Oct 17 14:29:58 2006 +++ pecl/http/http_send_api.c Tue Oct 17 19:13:16 2006 @@ -10,7 +10,7 @@ +--------------------------------------------------------------------+ */ -/* $Id: http_send_api.c,v 1.64 2006/10/17 14:29:58 mike Exp $ */ +/* $Id: http_send_api.c,v 1.65 2006/10/17 19:13:16 mike Exp $ */ #define HTTP_WANT_SAPI #define HTTP_WANT_ZLIB @@ -200,7 +200,7 @@ /* {{{ void http_send_header_zval(char*, zval **, zend_bool) */ PHP_HTTP_API void _http_send_header_zval_ex(const char *name, size_t name_len, zval **val, zend_bool replace TSRMLS_DC) { - if (!val || Z_TYPE_PP(val) == IS_NULL || (Z_TYPE_PP(val) == IS_STRING && !Z_STRLEN_PP(val))) { + if (!val || !*val || Z_TYPE_PP(val) == IS_NULL || (Z_TYPE_PP(val) == IS_STRING && !Z_STRLEN_PP(val))) { http_hide_header_ex(name, name_len); } else if (Z_TYPE_PP(val) == IS_ARRAY || Z_TYPE_PP(val) == IS_OBJECT) { zend_bool first = replace;

« previous php.pecl.cvs (#6498) next »