com php-src: Merge branch 'PHP-5.4' into PHP-5.5: ext/intl/loca le/locale_methods.c ext/spl/spl_array.c ext/standar d/info.c

From: Date: Tue, 24 Jun 2014 17:25:09 +0000
Subject: com php-src: Merge branch 'PHP-5.4' into PHP-5.5: ext/intl/loca le/locale_methods.c ext/spl/spl_array.c ext/standar d/info.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-79046@lists.php.net to get a copy of this message
Commit: e2ed4874b54b7d3673d68a6790a91bb85e3eb2e6 Author: Stanislav Malyshev <stas@php.net> Tue, 24 Jun 2014 10:25:09 -0700 Parents: 7ffcb48184a454fbe491e650fd177e07d713b2d6 3488cf6fd8a6510bf523a877eb63e86d39c7f9bd Branches: PHP-5.5 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=e2ed4874b54b7d3673d68a6790a91bb85e3eb2e6 Log: Merge branch 'PHP-5.4' into PHP-5.5 * PHP-5.4: 5.4.30 Better fix for bug #67072 with more BC provisions Fix bug #67498 - phpinfo() Type Confusion Information Leak Vulnerability update CVE Fix bug #67492: unserialize() SPL ArrayObject / SPLObjectStorage Type Confusion Fix bug #67397 (Buffer overflow in locale_get_display_name->uloc_getDisplayName (libicu 4.8.1)) Fix bug #67349: Locale::parseLocale Double Free add CVEs Fix potential segfault in dns_get_record() Fix bug #66127 (Segmentation fault with ArrayObject unset) 5.4.30 rc1 Conflicts: ext/intl/locale/locale_methods.c Bugs: https://bugs.php.net/67072 https://bugs.php.net/67498 https://bugs.php.net/67492 https://bugs.php.net/67397 https://bugs.php.net/67349 https://bugs.php.net/66127 Changed paths: MM ext/intl/locale/locale_methods.c MM ext/spl/spl_array.c MM ext/standard/info.c Diff: diff --cc ext/intl/locale/locale_methods.c index 21b5847,3bb5648..f1e1849 --- a/ext/intl/locale/locale_methods.c +++ b/ext/intl/locale/locale_methods.c @@@ -280,8 -282,8 +279,8 @@@ static char* get_icu_value_internal( co if( fromParseLocale==1 ){ /* Handle singletons */ if( strcmp(tag_name , LOC_LANG_TAG)==0 ){ - if( strlen(loc_name)>1 && (isIDPrefix(loc_name) ==1 ) ){ - return (char *)loc_name; - if( strlen(loc_name)>1 && isIDPrefix(loc_name) ){ ++ if( strlen(loc_name)>1 && (isIDPrefix(loc_name) == 1) ){ + return estrdup(loc_name); } } @@@ -498,8 -500,16 +497,16 @@@ static void get_icu_disp_value_src_php RETURN_FALSE; } + if(loc_name_len > ULOC_FULLNAME_CAPACITY) { + /* See bug 67397: overlong locale names cause trouble in uloc_getDisplayName */ + spprintf(&msg , 0, "locale_get_display_%s : name too long", tag_name ); + intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR, msg , 1 TSRMLS_CC ); + efree(msg); + RETURN_FALSE; + } + if(loc_name_len == 0) { - loc_name = INTL_G(default_locale); + loc_name = intl_locale_get_default(TSRMLS_C); } if( strcmp(tag_name, DISP_NAME) != 0 ){

« previous php.cvs (#79046) next »