diff options
author | Xinchen Hui <laruence@gmail.com> | 2015-12-08 17:47:16 -0800 |
---|---|---|
committer | Xinchen Hui <laruence@gmail.com> | 2015-12-08 17:47:16 -0800 |
commit | 84b997020ea47b10172207196136291c5ff09443 (patch) | |
tree | b641cbaa4609d5691f42761ea0c8c1ba8d999978 /ext/mbstring | |
parent | adb95227676f389788230e3e649cda2b55342948 (diff) | |
download | php-git-84b997020ea47b10172207196136291c5ff09443.tar.gz |
Fixed bug #71066 (mb_send_mail: Program terminated with signal SIGSEGV, Segmentation fault)
Diffstat (limited to 'ext/mbstring')
-rw-r--r-- | ext/mbstring/mbstring.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index c0c622a51e..09994f649b 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -4109,11 +4109,12 @@ PHP_FUNCTION(mb_send_mail) _php_mbstr_parse_mail_headers(&ht_headers, headers, headers_len); } - if ((s = zend_hash_str_find_ptr(&ht_headers, "CONTENT-TYPE", sizeof("CONTENT-TYPE") - 1))) { + if ((s = zend_hash_str_find(&ht_headers, "CONTENT-TYPE", sizeof("CONTENT-TYPE") - 1))) { char *tmp; char *param_name; char *charset = NULL; + ZEND_ASSERT(Z_TYPE_P(s) == IS_STRING); p = strchr(Z_STRVAL_P(s), ';'); if (p != NULL) { |