com php-src: Fixed refernce handling: ext/intl/dateformat/datef ormat_parse.c

From: Date: Sat, 28 Jun 2014 13:09:07 +0000
Subject: com php-src: Fixed refernce handling: ext/intl/dateformat/datef ormat_parse.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-79102@lists.php.net to get a copy of this message
Commit: d01e06e18a96dc6c2844198ee67e77ab7021456b Author: Xinchen Hui <laruence@php.net> Sat, 28 Jun 2014 21:09:07 +0800 Parents: a1426c62d515f74125de3a6b6cffc2004c81ba5c Branches: phpng Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=d01e06e18a96dc6c2844198ee67e77ab7021456b Log: Fixed refernce handling Changed paths: M ext/intl/dateformat/dateformat_parse.c Diff: diff --git a/ext/intl/dateformat/dateformat_parse.c b/ext/intl/dateformat/dateformat_parse.c index 9930778..f981afb 100644 --- a/ext/intl/dateformat/dateformat_parse.c +++ b/ext/intl/dateformat/dateformat_parse.c @@ -182,7 +182,8 @@ PHP_FUNCTION(datefmt_localtime) /* Fetch the object. */ DATE_FORMAT_METHOD_FETCH_OBJECT; - if(z_parse_pos) { + if (z_parse_pos) { + ZVAL_DEREF(z_parse_pos); convert_to_long(z_parse_pos); parse_pos = (int32_t)Z_LVAL_P(z_parse_pos); if(parse_pos > text_len) { @@ -190,7 +191,7 @@ PHP_FUNCTION(datefmt_localtime) } } internal_parse_to_localtime( dfo, text_to_parse, text_len, z_parse_pos?&parse_pos:NULL, return_value TSRMLS_CC); - if(z_parse_pos) { + if (z_parse_pos) { zval_dtor(z_parse_pos); ZVAL_LONG(z_parse_pos, parse_pos); }

« previous php.cvs (#79102) next »