cvs: php-src(PHP_5_3) /ext/mbstring mbstring.c /ext/mbstring/tests zend_multibyte-02.phpt zend_multibyte-03.phpt zend_multibyte-04.phpt
zend_multibyte-05.phpt zend_multibyte-06.phpt zend_multibyte-07.phpt zend_multibyte-08.phpt zend_multibyte-09.phpt zend_multibyte-10.phpt
zend_multibyte-11.phpt zend_multibyte-12.phpt zend_multibyte-13.phpt zend_multibyte-14.phpt

From: Date: Sun, 10 May 2009 21:04:46 +0000
Subject: cvs: php-src(PHP_5_3) /ext/mbstring mbstring.c /ext/mbstring/tests zend_multibyte-02.phpt zend_multibyte-03.phpt zend_multibyte-04.phpt
zend_multibyte-05.phpt zend_multibyte-06.phpt zend_multibyte-07.phpt zend_multibyte-08.phpt zend_multibyte-09.phpt zend_multibyte-10.phpt
zend_multibyte-11.phpt zend_multibyte-12.phpt zend_multibyte-13.phpt zend_multibyte-14.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-57696@lists.php.net to get a copy of this message
jani Sun May 10 21:04:46 2009 UTC Modified files: (Branch: PHP_5_3) /php-src/ext/mbstring mbstring.c /php-src/ext/mbstring/tests zend_multibyte-02.phpt zend_multibyte-03.phpt zend_multibyte-04.phpt zend_multibyte-05.phpt zend_multibyte-06.phpt zend_multibyte-07.phpt zend_multibyte-08.phpt zend_multibyte-09.phpt zend_multibyte-10.phpt zend_multibyte-11.phpt zend_multibyte-12.phpt zend_multibyte-13.phpt zend_multibyte-14.phpt Log: - Fixed bug #48200 (compile failure with mbstring.c when --enable-zend-multibyte is used)

http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/mbstring.c?r1=1.224.2.22.2.25.2.53&r2=1.224.2.22.2.25.2.54&diff_format=u Index: php-src/ext/mbstring/mbstring.c diff -u php-src/ext/mbstring/mbstring.c:1.224.2.22.2.25.2.53 php-src/ext/mbstring/mbstring.c:1.224.2.22.2.25.2.54 --- php-src/ext/mbstring/mbstring.c:1.224.2.22.2.25.2.53 Mon Apr 20 16:07:59 2009 +++ php-src/ext/mbstring/mbstring.c Sun May 10 21:04:46 2009 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: mbstring.c,v 1.224.2.22.2.25.2.53 2009/04/20 16:07:59 jani Exp $ */ +/* $Id: mbstring.c,v 1.224.2.22.2.25.2.54 2009/05/10 21:04:46 jani Exp $ */ /* * PHP 4 Multibyte String module "mbstring" @@ -94,8 +94,14 @@ /* {{{ prototypes */ ZEND_DECLARE_MODULE_GLOBALS(mbstring) + static PHP_GINIT_FUNCTION(mbstring); static PHP_GSHUTDOWN_FUNCTION(mbstring); + +static size_t php_mb_oddlen(const unsigned char *string, size_t length, const char *encoding TSRMLS_DC); +static int php_mb_encoding_converter(unsigned char **to, size_t *to_length, const unsigned char *from, size_t from_length, const char *encoding_to, const char *encoding_from TSRMLS_DC); +static char* php_mb_encoding_detector(const unsigned char *arg_string, size_t arg_length, char *arg_list TSRMLS_DC); +static int php_mb_set_zend_encoding(TSRMLS_D); /* }}} */ /* {{{ php_mb_default_identify_list */ @@ -866,7 +872,7 @@ #if HAVE_ONIG /* {{{ _php_mb_compile_regex */ -void *_php_mb_compile_regex(const char *pattern TSRMLS_DC) +static void *_php_mb_compile_regex(const char *pattern TSRMLS_DC) { php_mb_regex_t *retval; OnigErrorInfo err_info; @@ -887,7 +893,7 @@ /* }}} */ /* {{{ _php_mb_match_regex */ -int _php_mb_match_regex(void *opaque, const char *str, size_t str_len) +static int _php_mb_match_regex(void *opaque, const char *str, size_t str_len) { return onig_search((php_mb_regex_t *)opaque, (const OnigUChar *)str, (const OnigUChar*)str + str_len, (const OnigUChar *)str, @@ -896,14 +902,14 @@ /* }}} */ /* {{{ _php_mb_free_regex */ -void _php_mb_free_regex(void *opaque) +static void _php_mb_free_regex(void *opaque) { onig_free((php_mb_regex_t *)opaque); } /* }}} */ #elif HAVE_PCRE || HAVE_BUNDLED_PCRE /* {{{ _php_mb_compile_regex */ -void *_php_mb_compile_regex(const char *pattern TSRMLS_DC) +static void *_php_mb_compile_regex(const char *pattern TSRMLS_DC) { pcre *retval; const char *err_str; @@ -918,7 +924,7 @@ /* }}} */ /* {{{ _php_mb_match_regex */ -int _php_mb_match_regex(void *opaque, const char *str, size_t str_len) +static int _php_mb_match_regex(void *opaque, const char *str, size_t str_len) { return pcre_exec((pcre *)opaque, NULL, str, (int)str_len, 0, 0, NULL, 0) >= 0; @@ -926,7 +932,7 @@ /* }}} */ /* {{{ _php_mb_free_regex */ -void _php_mb_free_regex(void *opaque) +static void _php_mb_free_regex(void *opaque) { pcre_free(opaque); } @@ -4720,7 +4726,6 @@ /* }}} */ #ifdef ZEND_MULTIBYTE - /* {{{ php_mb_set_zend_encoding() */ static int php_mb_set_zend_encoding(TSRMLS_D) { @@ -4812,9 +4817,7 @@ /* }}} */ /* {{{ int php_mb_encoding_converter() */ -static int php_mb_encoding_converter(unsigned char **to, size_t *to_length, - const unsigned char *from, size_t from_length, - const char *encoding_to, const char *encoding_from TSRMLS_DC) +static int php_mb_encoding_converter(unsigned char **to, size_t *to_length, const unsigned char *from, size_t from_length, const char *encoding_to, const char *encoding_from TSRMLS_DC) { mbfl_string string, result, *ret; enum mbfl_no_encoding from_encoding, to_encoding; http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-02.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-02.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-02.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-02.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-02.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-02.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (2) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=UTF-8 http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-03.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-03.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-03.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-03.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-03.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-03.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (3) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=UTF-8 http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-04.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-04.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-04.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-04.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-04.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-04.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (4) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=CP932 http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-05.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-05.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-05.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-05.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-05.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-05.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (5) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=EUC-JP http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-06.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-06.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-06.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-06.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-06.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-06.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (6) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=EUC-JP http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-07.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-07.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-07.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-07.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-07.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-07.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (7) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=ISO-8859-1 http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-08.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-08.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-08.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-08.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-08.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-08.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (8) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=ISO-8859-1 http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-09.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-09.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-09.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-09.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-09.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-09.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (9) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=cp1251 http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-10.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-10.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-10.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-10.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-10.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-10.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (10) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --FILE-- <?php http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-11.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-11.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-11.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-11.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-11.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-11.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (11) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --FILE-- <?php http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-12.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-12.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-12.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-12.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-12.phpt:1.1.2.2 Fri Jul 25 10:48:20 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-12.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (12) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --FILE-- <?php http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-13.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-13.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-13.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-13.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-13.phpt:1.1.2.2 Mon Jul 28 06:13:57 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-13.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (13) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=UTF-8 http://cvs.php.net/viewvc.cgi/php-src/ext/mbstring/tests/zend_multibyte-14.phpt?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: php-src/ext/mbstring/tests/zend_multibyte-14.phpt diff -u php-src/ext/mbstring/tests/zend_multibyte-14.phpt:1.1.2.2 php-src/ext/mbstring/tests/zend_multibyte-14.phpt:1.1.2.3 --- php-src/ext/mbstring/tests/zend_multibyte-14.phpt:1.1.2.2 Tue Jul 29 00:02:12 2008 +++ php-src/ext/mbstring/tests/zend_multibyte-14.phpt Sun May 10 21:04:46 2009 @@ -2,9 +2,10 @@ zend multibyte (14) --SKIPIF-- <?php -ini_set("mbstring.script_encoding", "SJIS"); -ini_set("mbstring.script_encoding", "***") != "SJIS" and +ini_set("mbstring.script_encoding","SJIS"); +if (ini_set("mbstring.script_encoding","SJIS") != "SJIS") { die("skip zend-multibyte is not available"); +} ?> --INI-- mbstring.script_encoding=UTF-8
« previous php.cvs (#57696) next »